package com.zshan.clinic.database.model;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDate;
import java.time.LocalTime;
import java.util.Date;

/**
 * 门诊病历表
 */
public class ClinicMedical implements Serializable {
    /** 病历ID;挂号ID */
    private Long medicalId;

    /** 诊号;唯一诊号 */
    private String visitNo;

    /** 就诊日期;2025-07-09 */
    private LocalDate visitDate;

    /** 就诊时段;就诊时段1.上午2下午3晚上 */
    private String visitPeriod;

    /** 排队序号;排队序号 1/2/3 */
    private Integer visitSeqNo;

    /** 就诊班次ID */
    private Long visitShiftId;

    /** 就诊开始时段;08：00 */
    private LocalTime visitStartTime;

    /** 就诊结束时段;08：15 */
    private LocalTime visitEndTime;

    /** 初诊类型;1、初诊 2、复诊 */
    private String visitType;

    /** 挂号类型;1、普通号 2、急诊 */
    private String regType;

    /** 医生ID */
    private Long doctorId;

    /** 医生名 */
    private String doctorName;

    /** 科室ID */
    private Long deptId;

    /** 科室名 */
    private String deptName;

    /** 诊室ID */
    private Long roomId;

    /** 诊室名 */
    private String roomName;

    /** 患者ID */
    private Long patientId;

    /** 患者名 */
    private String patientName;

    /** 患者性别;1男生2女生3未知 */
    private String patientGender;

    /** 患者电话 */
    private String patientPhone;

    /** 身份证号 */
    private String idCard;

    /** 年龄年;5代表5岁 */
    private Integer ageYear;

    /** 年龄月;2代表2个月 */
    private Integer ageMonth;

    /** 阳历生日;阳历生日 */
    private LocalDate solarBirthday;

    /** 阴历生日;阴历生日 */
    private LocalDate lunarBirthday;

    /** 体重;53.8kg */
    private BigDecimal weight;

    /** 收缩压;120mmHg */
    private Integer systolicBp;

    /** 舒张压;80mmHg */
    private Integer diastolicBp;

    /** 就诊状态;1、待诊2、已诊 */
    private String visitStatus;

    /** 是否随访;1是0否 */
    private String isFollowUp;

    /** 几天后随访 */
    private Integer followUpDays;

    /** 医嘱事项 */
    private String doctorAdvice;

    /** 主诉 */
    private String complaint;

    /** 最后诊断 */
    private String diagnosis;

    /** 诊断时间 */
    private Date diagnosisTime;

    /** 挂号ID */
    private Long registerId;

    /** 排序号 */
    private Integer sortNum;

    /** 诊所ID */
    private Long clinicId;

    /** 启用状态;启用状态 */
    private String isEnabled;

    /** 删除标识 */
    private String isDelete;

    /** 创建人ID */
    private Long createUserId;

    /** 创建人 */
    private String createBy;

    /** 创建时间 */
    private Date createTime;

    /** 更新人ID */
    private Long updateUserId;

    /** 更新人 */
    private String updateBy;

    /** 更新时间 */
    private Date updateTime;

    private static final long serialVersionUID = 1L;

    public Long getMedicalId() {
        return medicalId;
    }

    public void setMedicalId(Long medicalId) {
        this.medicalId = medicalId;
    }

    public String getVisitNo() {
        return visitNo;
    }

    public void setVisitNo(String visitNo) {
        this.visitNo = visitNo == null ? null : visitNo.trim();
    }

    public LocalDate getVisitDate() {
        return visitDate;
    }

    public void setVisitDate(LocalDate visitDate) {
        this.visitDate = visitDate;
    }

    public String getVisitPeriod() {
        return visitPeriod;
    }

    public void setVisitPeriod(String visitPeriod) {
        this.visitPeriod = visitPeriod == null ? null : visitPeriod.trim();
    }

    public Integer getVisitSeqNo() {
        return visitSeqNo;
    }

    public void setVisitSeqNo(Integer visitSeqNo) {
        this.visitSeqNo = visitSeqNo;
    }

    public Long getVisitShiftId() {
        return visitShiftId;
    }

    public void setVisitShiftId(Long visitShiftId) {
        this.visitShiftId = visitShiftId;
    }

    public LocalTime getVisitStartTime() {
        return visitStartTime;
    }

    public void setVisitStartTime(LocalTime visitStartTime) {
        this.visitStartTime = visitStartTime;
    }

    public LocalTime getVisitEndTime() {
        return visitEndTime;
    }

    public void setVisitEndTime(LocalTime visitEndTime) {
        this.visitEndTime = visitEndTime;
    }

    public String getVisitType() {
        return visitType;
    }

    public void setVisitType(String visitType) {
        this.visitType = visitType == null ? null : visitType.trim();
    }

    public String getRegType() {
        return regType;
    }

    public void setRegType(String regType) {
        this.regType = regType == null ? null : regType.trim();
    }

    public Long getDoctorId() {
        return doctorId;
    }

    public void setDoctorId(Long doctorId) {
        this.doctorId = doctorId;
    }

    public String getDoctorName() {
        return doctorName;
    }

    public void setDoctorName(String doctorName) {
        this.doctorName = doctorName == null ? null : doctorName.trim();
    }

    public Long getDeptId() {
        return deptId;
    }

    public void setDeptId(Long deptId) {
        this.deptId = deptId;
    }

    public String getDeptName() {
        return deptName;
    }

    public void setDeptName(String deptName) {
        this.deptName = deptName == null ? null : deptName.trim();
    }

    public Long getRoomId() {
        return roomId;
    }

    public void setRoomId(Long roomId) {
        this.roomId = roomId;
    }

    public String getRoomName() {
        return roomName;
    }

    public void setRoomName(String roomName) {
        this.roomName = roomName == null ? null : roomName.trim();
    }

    public Long getPatientId() {
        return patientId;
    }

    public void setPatientId(Long patientId) {
        this.patientId = patientId;
    }

    public String getPatientName() {
        return patientName;
    }

    public void setPatientName(String patientName) {
        this.patientName = patientName == null ? null : patientName.trim();
    }

    public String getPatientGender() {
        return patientGender;
    }

    public void setPatientGender(String patientGender) {
        this.patientGender = patientGender == null ? null : patientGender.trim();
    }

    public String getPatientPhone() {
        return patientPhone;
    }

    public void setPatientPhone(String patientPhone) {
        this.patientPhone = patientPhone == null ? null : patientPhone.trim();
    }

    public String getIdCard() {
        return idCard;
    }

    public void setIdCard(String idCard) {
        this.idCard = idCard == null ? null : idCard.trim();
    }

    public Integer getAgeYear() {
        return ageYear;
    }

    public void setAgeYear(Integer ageYear) {
        this.ageYear = ageYear;
    }

    public Integer getAgeMonth() {
        return ageMonth;
    }

    public void setAgeMonth(Integer ageMonth) {
        this.ageMonth = ageMonth;
    }

    public LocalDate getSolarBirthday() {
        return solarBirthday;
    }

    public void setSolarBirthday(LocalDate solarBirthday) {
        this.solarBirthday = solarBirthday;
    }

    public LocalDate getLunarBirthday() {
        return lunarBirthday;
    }

    public void setLunarBirthday(LocalDate lunarBirthday) {
        this.lunarBirthday = lunarBirthday;
    }

    public BigDecimal getWeight() {
        return weight;
    }

    public void setWeight(BigDecimal weight) {
        this.weight = weight;
    }

    public Integer getSystolicBp() {
        return systolicBp;
    }

    public void setSystolicBp(Integer systolicBp) {
        this.systolicBp = systolicBp;
    }

    public Integer getDiastolicBp() {
        return diastolicBp;
    }

    public void setDiastolicBp(Integer diastolicBp) {
        this.diastolicBp = diastolicBp;
    }

    public String getVisitStatus() {
        return visitStatus;
    }

    public void setVisitStatus(String visitStatus) {
        this.visitStatus = visitStatus == null ? null : visitStatus.trim();
    }

    public String getIsFollowUp() {
        return isFollowUp;
    }

    public void setIsFollowUp(String isFollowUp) {
        this.isFollowUp = isFollowUp == null ? null : isFollowUp.trim();
    }

    public Integer getFollowUpDays() {
        return followUpDays;
    }

    public void setFollowUpDays(Integer followUpDays) {
        this.followUpDays = followUpDays;
    }

    public String getDoctorAdvice() {
        return doctorAdvice;
    }

    public void setDoctorAdvice(String doctorAdvice) {
        this.doctorAdvice = doctorAdvice == null ? null : doctorAdvice.trim();
    }

    public String getComplaint() {
        return complaint;
    }

    public void setComplaint(String complaint) {
        this.complaint = complaint == null ? null : complaint.trim();
    }

    public String getDiagnosis() {
        return diagnosis;
    }

    public void setDiagnosis(String diagnosis) {
        this.diagnosis = diagnosis == null ? null : diagnosis.trim();
    }

    public Date getDiagnosisTime() {
        return diagnosisTime;
    }

    public void setDiagnosisTime(Date diagnosisTime) {
        this.diagnosisTime = diagnosisTime;
    }

    public Long getRegisterId() {
        return registerId;
    }

    public void setRegisterId(Long registerId) {
        this.registerId = registerId;
    }

    public Integer getSortNum() {
        return sortNum;
    }

    public void setSortNum(Integer sortNum) {
        this.sortNum = sortNum;
    }

    public Long getClinicId() {
        return clinicId;
    }

    public void setClinicId(Long clinicId) {
        this.clinicId = clinicId;
    }

    public String getIsEnabled() {
        return isEnabled;
    }

    public void setIsEnabled(String isEnabled) {
        this.isEnabled = isEnabled == null ? null : isEnabled.trim();
    }

    public String getIsDelete() {
        return isDelete;
    }

    public void setIsDelete(String isDelete) {
        this.isDelete = isDelete == null ? null : isDelete.trim();
    }

    public Long getCreateUserId() {
        return createUserId;
    }

    public void setCreateUserId(Long createUserId) {
        this.createUserId = createUserId;
    }

    public String getCreateBy() {
        return createBy;
    }

    public void setCreateBy(String createBy) {
        this.createBy = createBy == null ? null : createBy.trim();
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Long getUpdateUserId() {
        return updateUserId;
    }

    public void setUpdateUserId(Long updateUserId) {
        this.updateUserId = updateUserId;
    }

    public String getUpdateBy() {
        return updateBy;
    }

    public void setUpdateBy(String updateBy) {
        this.updateBy = updateBy == null ? null : updateBy.trim();
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        ClinicMedical other = (ClinicMedical) that;
        return (this.getMedicalId() == null ? other.getMedicalId() == null : this.getMedicalId().equals(other.getMedicalId()))
            && (this.getVisitNo() == null ? other.getVisitNo() == null : this.getVisitNo().equals(other.getVisitNo()))
            && (this.getVisitDate() == null ? other.getVisitDate() == null : this.getVisitDate().equals(other.getVisitDate()))
            && (this.getVisitPeriod() == null ? other.getVisitPeriod() == null : this.getVisitPeriod().equals(other.getVisitPeriod()))
            && (this.getVisitSeqNo() == null ? other.getVisitSeqNo() == null : this.getVisitSeqNo().equals(other.getVisitSeqNo()))
            && (this.getVisitShiftId() == null ? other.getVisitShiftId() == null : this.getVisitShiftId().equals(other.getVisitShiftId()))
            && (this.getVisitStartTime() == null ? other.getVisitStartTime() == null : this.getVisitStartTime().equals(other.getVisitStartTime()))
            && (this.getVisitEndTime() == null ? other.getVisitEndTime() == null : this.getVisitEndTime().equals(other.getVisitEndTime()))
            && (this.getVisitType() == null ? other.getVisitType() == null : this.getVisitType().equals(other.getVisitType()))
            && (this.getRegType() == null ? other.getRegType() == null : this.getRegType().equals(other.getRegType()))
            && (this.getDoctorId() == null ? other.getDoctorId() == null : this.getDoctorId().equals(other.getDoctorId()))
            && (this.getDoctorName() == null ? other.getDoctorName() == null : this.getDoctorName().equals(other.getDoctorName()))
            && (this.getDeptId() == null ? other.getDeptId() == null : this.getDeptId().equals(other.getDeptId()))
            && (this.getDeptName() == null ? other.getDeptName() == null : this.getDeptName().equals(other.getDeptName()))
            && (this.getRoomId() == null ? other.getRoomId() == null : this.getRoomId().equals(other.getRoomId()))
            && (this.getRoomName() == null ? other.getRoomName() == null : this.getRoomName().equals(other.getRoomName()))
            && (this.getPatientId() == null ? other.getPatientId() == null : this.getPatientId().equals(other.getPatientId()))
            && (this.getPatientName() == null ? other.getPatientName() == null : this.getPatientName().equals(other.getPatientName()))
            && (this.getPatientGender() == null ? other.getPatientGender() == null : this.getPatientGender().equals(other.getPatientGender()))
            && (this.getPatientPhone() == null ? other.getPatientPhone() == null : this.getPatientPhone().equals(other.getPatientPhone()))
            && (this.getIdCard() == null ? other.getIdCard() == null : this.getIdCard().equals(other.getIdCard()))
            && (this.getAgeYear() == null ? other.getAgeYear() == null : this.getAgeYear().equals(other.getAgeYear()))
            && (this.getAgeMonth() == null ? other.getAgeMonth() == null : this.getAgeMonth().equals(other.getAgeMonth()))
            && (this.getSolarBirthday() == null ? other.getSolarBirthday() == null : this.getSolarBirthday().equals(other.getSolarBirthday()))
            && (this.getLunarBirthday() == null ? other.getLunarBirthday() == null : this.getLunarBirthday().equals(other.getLunarBirthday()))
            && (this.getWeight() == null ? other.getWeight() == null : this.getWeight().equals(other.getWeight()))
            && (this.getSystolicBp() == null ? other.getSystolicBp() == null : this.getSystolicBp().equals(other.getSystolicBp()))
            && (this.getDiastolicBp() == null ? other.getDiastolicBp() == null : this.getDiastolicBp().equals(other.getDiastolicBp()))
            && (this.getVisitStatus() == null ? other.getVisitStatus() == null : this.getVisitStatus().equals(other.getVisitStatus()))
            && (this.getIsFollowUp() == null ? other.getIsFollowUp() == null : this.getIsFollowUp().equals(other.getIsFollowUp()))
            && (this.getFollowUpDays() == null ? other.getFollowUpDays() == null : this.getFollowUpDays().equals(other.getFollowUpDays()))
            && (this.getDoctorAdvice() == null ? other.getDoctorAdvice() == null : this.getDoctorAdvice().equals(other.getDoctorAdvice()))
            && (this.getComplaint() == null ? other.getComplaint() == null : this.getComplaint().equals(other.getComplaint()))
            && (this.getDiagnosis() == null ? other.getDiagnosis() == null : this.getDiagnosis().equals(other.getDiagnosis()))
            && (this.getDiagnosisTime() == null ? other.getDiagnosisTime() == null : this.getDiagnosisTime().equals(other.getDiagnosisTime()))
            && (this.getRegisterId() == null ? other.getRegisterId() == null : this.getRegisterId().equals(other.getRegisterId()))
            && (this.getSortNum() == null ? other.getSortNum() == null : this.getSortNum().equals(other.getSortNum()))
            && (this.getClinicId() == null ? other.getClinicId() == null : this.getClinicId().equals(other.getClinicId()))
            && (this.getIsEnabled() == null ? other.getIsEnabled() == null : this.getIsEnabled().equals(other.getIsEnabled()))
            && (this.getIsDelete() == null ? other.getIsDelete() == null : this.getIsDelete().equals(other.getIsDelete()))
            && (this.getCreateUserId() == null ? other.getCreateUserId() == null : this.getCreateUserId().equals(other.getCreateUserId()))
            && (this.getCreateBy() == null ? other.getCreateBy() == null : this.getCreateBy().equals(other.getCreateBy()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateUserId() == null ? other.getUpdateUserId() == null : this.getUpdateUserId().equals(other.getUpdateUserId()))
            && (this.getUpdateBy() == null ? other.getUpdateBy() == null : this.getUpdateBy().equals(other.getUpdateBy()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getMedicalId() == null) ? 0 : getMedicalId().hashCode());
        result = prime * result + ((getVisitNo() == null) ? 0 : getVisitNo().hashCode());
        result = prime * result + ((getVisitDate() == null) ? 0 : getVisitDate().hashCode());
        result = prime * result + ((getVisitPeriod() == null) ? 0 : getVisitPeriod().hashCode());
        result = prime * result + ((getVisitSeqNo() == null) ? 0 : getVisitSeqNo().hashCode());
        result = prime * result + ((getVisitShiftId() == null) ? 0 : getVisitShiftId().hashCode());
        result = prime * result + ((getVisitStartTime() == null) ? 0 : getVisitStartTime().hashCode());
        result = prime * result + ((getVisitEndTime() == null) ? 0 : getVisitEndTime().hashCode());
        result = prime * result + ((getVisitType() == null) ? 0 : getVisitType().hashCode());
        result = prime * result + ((getRegType() == null) ? 0 : getRegType().hashCode());
        result = prime * result + ((getDoctorId() == null) ? 0 : getDoctorId().hashCode());
        result = prime * result + ((getDoctorName() == null) ? 0 : getDoctorName().hashCode());
        result = prime * result + ((getDeptId() == null) ? 0 : getDeptId().hashCode());
        result = prime * result + ((getDeptName() == null) ? 0 : getDeptName().hashCode());
        result = prime * result + ((getRoomId() == null) ? 0 : getRoomId().hashCode());
        result = prime * result + ((getRoomName() == null) ? 0 : getRoomName().hashCode());
        result = prime * result + ((getPatientId() == null) ? 0 : getPatientId().hashCode());
        result = prime * result + ((getPatientName() == null) ? 0 : getPatientName().hashCode());
        result = prime * result + ((getPatientGender() == null) ? 0 : getPatientGender().hashCode());
        result = prime * result + ((getPatientPhone() == null) ? 0 : getPatientPhone().hashCode());
        result = prime * result + ((getIdCard() == null) ? 0 : getIdCard().hashCode());
        result = prime * result + ((getAgeYear() == null) ? 0 : getAgeYear().hashCode());
        result = prime * result + ((getAgeMonth() == null) ? 0 : getAgeMonth().hashCode());
        result = prime * result + ((getSolarBirthday() == null) ? 0 : getSolarBirthday().hashCode());
        result = prime * result + ((getLunarBirthday() == null) ? 0 : getLunarBirthday().hashCode());
        result = prime * result + ((getWeight() == null) ? 0 : getWeight().hashCode());
        result = prime * result + ((getSystolicBp() == null) ? 0 : getSystolicBp().hashCode());
        result = prime * result + ((getDiastolicBp() == null) ? 0 : getDiastolicBp().hashCode());
        result = prime * result + ((getVisitStatus() == null) ? 0 : getVisitStatus().hashCode());
        result = prime * result + ((getIsFollowUp() == null) ? 0 : getIsFollowUp().hashCode());
        result = prime * result + ((getFollowUpDays() == null) ? 0 : getFollowUpDays().hashCode());
        result = prime * result + ((getDoctorAdvice() == null) ? 0 : getDoctorAdvice().hashCode());
        result = prime * result + ((getComplaint() == null) ? 0 : getComplaint().hashCode());
        result = prime * result + ((getDiagnosis() == null) ? 0 : getDiagnosis().hashCode());
        result = prime * result + ((getDiagnosisTime() == null) ? 0 : getDiagnosisTime().hashCode());
        result = prime * result + ((getRegisterId() == null) ? 0 : getRegisterId().hashCode());
        result = prime * result + ((getSortNum() == null) ? 0 : getSortNum().hashCode());
        result = prime * result + ((getClinicId() == null) ? 0 : getClinicId().hashCode());
        result = prime * result + ((getIsEnabled() == null) ? 0 : getIsEnabled().hashCode());
        result = prime * result + ((getIsDelete() == null) ? 0 : getIsDelete().hashCode());
        result = prime * result + ((getCreateUserId() == null) ? 0 : getCreateUserId().hashCode());
        result = prime * result + ((getCreateBy() == null) ? 0 : getCreateBy().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateUserId() == null) ? 0 : getUpdateUserId().hashCode());
        result = prime * result + ((getUpdateBy() == null) ? 0 : getUpdateBy().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", medicalId=").append(medicalId);
        sb.append(", visitNo=").append(visitNo);
        sb.append(", visitDate=").append(visitDate);
        sb.append(", visitPeriod=").append(visitPeriod);
        sb.append(", visitSeqNo=").append(visitSeqNo);
        sb.append(", visitShiftId=").append(visitShiftId);
        sb.append(", visitStartTime=").append(visitStartTime);
        sb.append(", visitEndTime=").append(visitEndTime);
        sb.append(", visitType=").append(visitType);
        sb.append(", regType=").append(regType);
        sb.append(", doctorId=").append(doctorId);
        sb.append(", doctorName=").append(doctorName);
        sb.append(", deptId=").append(deptId);
        sb.append(", deptName=").append(deptName);
        sb.append(", roomId=").append(roomId);
        sb.append(", roomName=").append(roomName);
        sb.append(", patientId=").append(patientId);
        sb.append(", patientName=").append(patientName);
        sb.append(", patientGender=").append(patientGender);
        sb.append(", patientPhone=").append(patientPhone);
        sb.append(", idCard=").append(idCard);
        sb.append(", ageYear=").append(ageYear);
        sb.append(", ageMonth=").append(ageMonth);
        sb.append(", solarBirthday=").append(solarBirthday);
        sb.append(", lunarBirthday=").append(lunarBirthday);
        sb.append(", weight=").append(weight);
        sb.append(", systolicBp=").append(systolicBp);
        sb.append(", diastolicBp=").append(diastolicBp);
        sb.append(", visitStatus=").append(visitStatus);
        sb.append(", isFollowUp=").append(isFollowUp);
        sb.append(", followUpDays=").append(followUpDays);
        sb.append(", doctorAdvice=").append(doctorAdvice);
        sb.append(", complaint=").append(complaint);
        sb.append(", diagnosis=").append(diagnosis);
        sb.append(", diagnosisTime=").append(diagnosisTime);
        sb.append(", registerId=").append(registerId);
        sb.append(", sortNum=").append(sortNum);
        sb.append(", clinicId=").append(clinicId);
        sb.append(", isEnabled=").append(isEnabled);
        sb.append(", isDelete=").append(isDelete);
        sb.append(", createUserId=").append(createUserId);
        sb.append(", createBy=").append(createBy);
        sb.append(", createTime=").append(createTime);
        sb.append(", updateUserId=").append(updateUserId);
        sb.append(", updateBy=").append(updateBy);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}